-- GENERATED SPELL FOR [Kreug Oathbreaker] --


function spell0_27105(pUnit, Event) --@Backbreaker,n/a--
pUnit:FullCastSpellOnTarget(53437,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_27105', 4302, 1)
end

function spell1_27105(pUnit, Event) --@Broken Oath,Self--
pUnit:FullCastSpellOnTarget(56310,pUnit)
pUnit:RegisterEvent('Sorts_27105', 10290, 1)
end

function spell2_27105(pUnit, Event) --@Incite Horror,n/a--
pUnit:FullCastSpellOnTarget(53438,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_27105', 5000, 1)
end

function Sorts_27105(pUnit, Event)
local choix_sorts_27105 = math.random(0, 2)
if choix_sorts_27105 == 0 then
pUnit:RegisterEvent('spell0_27105', 1, 1)
end
if choix_sorts_27105 == 1 then
pUnit:RegisterEvent('spell1_27105', 1, 1)
end
if choix_sorts_27105 == 2 then
pUnit:RegisterEvent('spell2_27105', 1, 1)
end
end

function mob27105_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_27105', math.random(1500, 3000), 1)
end

function mob27105_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob27105_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob27105_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(27105, 1, 'mob27105_Action')
RegisterUnitEvent(27105, 2, 'mob27105_Leave')
RegisterUnitEvent(27105, 3, 'mob27105_Kill')
RegisterUnitEvent(27105, 4, 'mob27105_Die')
